package com.qf.smsplatform.webmaster.mapper;

import com.qf.smsplatform.webmaster.pojo.TDirtyword;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface DirtywordMapper {
    @Select("select * from t_dirtyword where id=#{id}")
    TDirtyword findDirtyById(Long id);

    @Insert("insert into t_dirtyword (dirtyword,owntype,creater) values (#{dirtyword},#{owntype},#{creater})")
    int addDirty(TDirtyword dirty);

//    @Select("select * from t_dirtyword")
    List<TDirtyword> selectAll();

    int updateDirty(TDirtyword tDirtyword);

    int deleteDirtyByIds(@Param("ids") List<Integer> ids);
    int deleteDirtyByIdsAndCreater(@Param("ids") List<Integer> ids,@Param("creater") long creater);
}
